/**
 * @file rank/elementary/luogu1035/main.cpp
 * @brief
 * @see
 * @author Ruiming Guo (guoruiming@stu.scu.edu.cn)
 * @copyright 2022
 * @date 2022/7/7 13:17:53
 **/

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef vector<int> vi;
int main() {
  // High rating and good luck!
  double s = 0;
  int k;
  cin >> k;
  int n = 0;
  while (s <= k) {
    n++;
    s += 1.0 / n;
  }
  cout << n << endl;
  return 0;
}
